package main

import (
	"fmt"
	"time"
)

func main() {
	go newTask()
	/*	i := 0
		for {
			i++
			fmt.Printf("main goroutine : i=%d\n", i)
			time.Sleep(1 * time.Second) //延时1s
		}*/
	fmt.Println("main goroutine exit")
}

func newTask() {
	i := 0
	for {
		i++
		fmt.Printf("new goroutine : i=%d\n", i)
		time.Sleep(1 * time.Second) //延时1s
	}
}
